unit cmdSetGroupVisibleOff;

interface

uses  classes, sysutils
    , nativeXml
//    , appMappldXmlNode
    , appMappldXmlCommand
    , appMappldTypes
//    , appMappldXmlContext
    , appMappldXmlGroup
;

type
    {------------------------------ TCmdSetGroupVisibleOff }

    {***************************************************************************
    * TCmdSetGroupVisibleOff
    ***************************************************************************}
    TCmdSetGroupVisibleOff = class( TMappldXmlCommand )
protected
    procedure   internalProccess(); override;
    end;

implementation

{*******************************************************************************
* internalProccess
*******************************************************************************}
procedure TCmdSetGroupVisibleOff.internalProccess();
var
    group : TMappldXmlGroup;

begin
    group := FxmlContext.groupsByCode[ FxmlNode.ValueAsString ];
    if ( group = nil ) then
    begin
        exit;
    end;

    group.flVisible := false;
end;

initialization

TMappldXmlCommand.registerCommandByCode( XML_CMD_SetGroupVisibleOff, TCmdSetGroupVisibleOff );

end.
